﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data.SqlClient;
using System.Data;
using QUANLIHOCSINH.BussinessObject;
using QUANLIHOCSINH.DataAccess;
using System.Windows.Forms;
namespace QUANLIHOCSINH.BussinessLogic
{
    class NHOMNGUOIDUNGBUS
    {
        ConnectData dataConn = new ConnectData();
        public DataTable LayDanhNhomNguoiDungThuong()
        {
            return dataConn.GetData("select * From NhomNguoiDung where manhom in ('3','4')");
        }
        //public bool ThemNguoiDung(NGUOIDUNG hs)
        //{
        //    if (kiemtranguoidung(hs))
        //    {

        //        string sql = string.Format("INSERT INTO NGUOIDUNG (manguoidung,matkhau,tennguoidung,gioitinh,diachi,manhom)  VALUES ('{0}','{1}','{2}','{3}','{4}','{5}')", hs.MaNguoiDung, hs.MatKhau, hs.TenNguoiDung, hs.GioiTinh, hs.DiaChi, hs.MaNhom);
        //        if (dataConn.ExecuteQuery(sql))
        //        {
        //            MessageBox.Show("Thêm Học Sinh Thàng Công", "Thông Tin", MessageBoxButtons.OK, MessageBoxIcon.Information);
        //            return true;
        //        }
        //    }
        //    return false;
        //}
    }
}
